<%= form_for(@booktable) do |f| %>
  <% if @booktable.errors.any? %>
    <div id="error_explanation">
      <h2><%= pluralize(@booktable.errors.count, t(:error)) %> <%= t(:er)%> </h2>

      <ul>
      <% @booktable.errors.full_messages.each do |msg| %>
        <li><%= msg %></li>
      <% end %>
      </ul>
    </div>
  <% end %>
<div style="margin-left:20px;">
  <div class="field">
    <%= f.label t(:namebook)%><br />
    <%= f.text_field :nameBook %>
  </div>
  <div class="field">
    <%= f.label t(:nameauthor) %><br />
    <%= f.text_field :nameAuthor %>
  </div>
  <div class="field">
    <%= f.label t(:typebook) %><br />
    <%= f.text_field :typeBook%>
  </div>
  <div class="field">
    <%= f.label t(:quantity) %><br />
    <%= f.text_field :quantity %>
  </div>
  <div class="field">
    <%= f.label t(:imagebook) %><br />
    <%= f.text_field :image %>
  </div>
  <div class="field">
    <%= f.label t(:description) %><br />
    <%= f.text_field :decription %>
  </div>
  <div class="actions">
    <%= f.submit t(:upd) %>
  </div>
</div>
<% end %>
